<?php
namespace app\admin\controller;
use think\Controller;
use think\Request;
use app\admin\model\Product as ProModel;
class Shoping  extends Controller
{
	public function formadd()//增加菜单
	{
		return $this->fetch();
	}
	public function img()//图片
	{
		return $this->fetch();
	}
	public function pinglun()//评论
	{
		return $this->fetch();
	}
	public function tables(ProModel $pro)//商品表
	{
		$this->tablepro($pro);
		return $this->fetch();
	}
	public function tablepro($pro)
	{
		$info =$pro->porductin();
		$this->assign('proin',$info);
	}
	public function uploadimg()//上传图片
	{
		return $this->fetch();
	}
	public function addcd(Request $req,ProModel $pro)//增加菜单
	{
		if(!$req->param('name')){
			return false;
		}
		if(!$pro->menuin($req->param())){
			return true;
		}
		 
	}
	public function menude(ProModel $pro)
	{
		return $pro->menuinfo();//初始化更新菜单
	}

}